package cn.newstrength.shangyujie.step;

import cn.newstrength.wtdf.web.exception.PAIException;
import cn.newstrength.wtdf.web.processor.Operation;
import cn.newstrength.wtdf.web.processor.OperationStep;

import java.util.Map;

/**
 * 配合服务调用，模拟一个
 * @author Xd
 *
 */
public class ProducerStep implements OperationStep {

	@Override
	public int excute(Operation oper) throws PAIException {
		String message = oper.getContext().getElementValue("message");
		oper.setTranStepResult(0, "SUCC", message);
		return 0;
	}

	@Override
	public int init(Map<String, String> param) {
		return 0;
	}

}
